<div ng-cloak id="custom_code" class="preview custom_code_edtior"
     ng-show="custom_code.editor_visible"
     ng-class="{ 'slide' : Editor.Gallery.visible }">
  <textarea spellcheck='false'
            focus-me="custom_code.editor_visible"
            ng-model="custom_code.text"
            ng-style="{ 'background-color': Color.parse(Theme.bg.color), 'color': Color.parse(Theme.fg.color) }"></textarea>
  <div class="cc_header">
    <p class="pull-left">Paste your code below and press Save button.</p>
  </div>
</div>
<div class="custom_code_btn_bar" ng-show="custom_code.editor_visible" ng-cloak>
  <a class="btn btn-small btn-danger" ng-click="custom_code.text ='';custom_code.editor_visible = false;update_preview()">
     &nbsp;Clear&nbsp;
  </a>
  <a class="btn btn-small btn-success" ng-click="update_preview()">
     &nbsp;&nbsp;&nbsp;Save&nbsp;&nbsp;&nbsp;
  </a>
</div>

<div class="btn-group custom_code_toggle_btn" ng-cloak ng-show="Theme.json">
  <a class="btn btn-mac btn-small"
     ng-click="custom_code.editor_visible = !custom_code.editor_visible"
     ng-class="{'active': custom_code.editor_visible}">
    Customize Preview Code
  </a>
</div>
